The present invention relates generally to improved methods, systems, and computer program products for optimizing query processing. More particularly, it relates to optimizing query processing by dynamically selecting alternative query access plans in executing queries.
In typical database querying, query optimizers operate to specify query access or execution plans. Structure Query Language (SQL) queries express what results are requested, but not how the results should be obtained. To implement an SQL statement, a query optimizer is responsible for transforming the SQL statement into a query access or execution plan composed of specific implementations. The query optimizer can select a query access or execution plan for a so-called best method of accessing the data in the database. Typically, this selection is done by generating many different join order strategies, evaluating the processing time of each, and selecting an access plan which can obtain an optimal querying, preferably, within an estimated run time. The access plan would also take into account a combination of optimization data including, but not limited to, an estimated amount of computational overhead, the number of physical Input/Output (“I/O”) operations, the execution time, and cost. Known optimizers function to manage query executions in the foregoing fashion. Nevertheless, producing an optimal access plan for any given SQL query statement is a complex problem.
Presently, there are no known approaches for dynamically selecting alternative query access plans based on additional computer resources being available. Moreover, there are no known approaches for dynamically selecting alternative query access plans based on such plans being significantly better than original query access plans as a result of the available additional computing resources. In addition, there are no approaches, whereby such resources to be available are dynamically available from logically partitioned and/or grid environments.
Accordingly, there are needs for methods, systems, and computer program products for dynamically selecting alternative query access plans based on additional computer resources being available. In addition, there are needs for methods, systems, and computer program products for dynamically selecting alternative query access plans based on such plans being significantly better than original query access plans as a result of the available additional computing resources. Furthermore, there are needs for methods, systems, and computer program products, whereby such additional resources are dynamically available from logically partitioned and/or grid environments.
Without such needs being satisfied, the true potential for optimizing query processing will not be entirely satisfied.